import layout from '../layout'
import NotMenuLayout from '../not-menu-layout'

const Main = layout

const routeConfig = [
    {
        path: '/login',
        component: resolve => require(['../Login'], resolve),
        meta: {
            title: 'login',
            isOpen: true
        }
    },
    {
        path: '/',
        redirect: '/homePage'
    },
    {
        path: '/home',
        component: Main,
        children: [
            {
                path: '/homePage',
                component: resolve => require(['../view/HomePage'], resolve),
                meta: {
                    isOpen: true
                }
            }
        ]

    },

    {
        path: '/case',
        component: Main,
        children: [
            {
                path: '/policyDraft',
                component: resolve => require(['../view/PolicyDraft'], resolve),
                meta: {
                    breadcrum: ['保单草稿']
                }
            },
            {
                path: '/reviewPolicy',
                component: resolve => require(['../view/ReviewPolicy'], resolve),
                meta: {
                    breadcrum: ['已投保单']
                }
            },
            {
                path: '/paidPolicy',
                component: resolve => require(['../view/PaidPolicy'], resolve),
                meta: {
                    breadcrum: ['待支付保单']
                }
            },
            {
                path: '/accidentInsurancePolicy',
                component: resolve => require(['../view/AccidentInsurancePolicy'], resolve),
                meta: {
                    breadcrum: ['出险保单']
                }
            }
        ]

    },
    {
        path: '/settlement',
        component: Main,
        children: [
            {
                path: '/settlementOfClaim',
                component: resolve => require(['../view/SettlementOfClaim'], resolve),
                meta: {
                    breadcrum: ['理赔管理']
                }
            }
        ]

    },
    {
        path: '/insureContainer',
        component: NotMenuLayout,
        children: [
            {
                path: '/temp1',
                meta: {
                    breadcrum: ['集装箱']
                },
                component: resolve => require(['../view/InsuranceType/temp1/index.vue'], resolve),
            },
            {
                path: '/license',
                meta: {
                    isOpen: true
                },
                component: resolve => require(['../layout/license.vue'], resolve)
            },
            {
                path: '/licence',
                meta: {
                    isOpen: true
                },
                component: resolve => require(['../layout/licence.vue'], resolve)
            },
        ]

    },
    {
        path: '/helpCenter',
        component: Main,
        children: [
            {
                path: '/helpCenter',
                meta: {
                    isOpen: true
                },
                component: resolve => require(['../view/HelpCenter/index.vue'], resolve)
            },
            {
                path: '/aboutUs',
                meta: {
                    isOpen: true
                },
                component: resolve => require(['../view/AboutUs/index.vue'], resolve)
            },
            
            
        ]

    },
    {
        path: '/invoiceMessage',
        component: Main,
        children: [

            {
                path: '/invoiced',
                component: resolve => require(['../view/Invoiced'], resolve),
                meta: {
                    breadcrum: ['已开发票']
                }
            },
            {
                path: '/noInvoiceIssued',
                component: resolve => require(['../view/NoInvoiceIssued'], resolve),
                meta: {
                    breadcrum: ['未申请保单发票']
                }
            },
            {
                path: '/noInvoiced',
                component: resolve => require(['../view/NoInvoiced'], resolve),
                meta: {
                    breadcrum: ['未开发票']
                }
            }
        ]

    },
    {
        path: '/insureMessage',
        component: Main,
        children: [
            {
                path: '/applicant',
                component: resolve => require(['../view/Applicant'], resolve),
                meta: {
                    breadcrum: ['常用投保人']
                }
            },
            {
                path: '/insured',
                component: resolve => require(['../view/Insured'], resolve),
                meta: {
                    breadcrum: ['常用被保险人']
                }
            }
        ]

    },
    {
        path: '/manageCenter',
        component: Main,
        children: [
            {
                path: '/invoiceMsg',
                component: resolve => require(['../view/InvoiceMsg'], resolve),
                meta: {
                    breadcrum: ['发票信息']
                }
            },
            {
                path: '/accountMessage',
                component: resolve => require(['../view/AccountMessage'], resolve),
                meta: {
                    breadcrum: ['账户维护']
                }
            },
            {
                path: '/passwordChange',
                component: resolve => require(['../view/PasswordChange'], resolve),
                meta: {
                    breadcrum: ['修改登录密码']
                }
            },
            {
                path: '/accountChange',
                component: resolve => require(['../view/AccountChange'], resolve),
                meta: {
                    breadcrum: ['账号变更']
                }
            },
            {
                path: '/bankAccount',
                component: resolve => require(['../view/BankAccount'], resolve),
                meta: {
                    breadcrum: ['银行账户']
                }
            },
            {
                path: '/payPassword',
                component: resolve => require(['../view/PayPassword'], resolve),
                meta: {
                    breadcrum: ['支付密码']
                }
            },
            {
                path: '/myWallet',
                component: resolve => require(['../view/MyWallet'], resolve),
                meta: {
                    breadcrum: ['我的钱包']
                }
            },

        ]

    },
    {
        path: '/paymentMes',
        component: Main,
        children: [
            {
                path: '/payment',
                component: resolve => require(['../view/Payment'], resolve),
                meta: {
                    breadcrum: ['支付']
                }
            }
        ]

    }
]

export default routeConfig